#!/bin/sh
#  Build on first use, then hand over to the binary. stdout stays clean: the
#  compiler talks to stderr only.
set -eu
root=$(CDPATH= cd -- "$(dirname -- "$0")/.." && pwd)
cd "$root"
app={{ npm_name }}
if [ ! -x "build/$app" ]; then
    make -s all APP="$app" >&2
fi
exec "build/$app" "$@"
